Show All

Range Property

       

Range property as it applies to the AutoFilter object.

Range property as it applies to the PivotData object.

Range property as it applies to the Range, Spreadsheet, and Worksheet objects.

Example

This example sets the row height to 15 points for rows 1 through 10.

Spreadsheet1.Range("a1:a10").RowHeight = 15

This example sets a variable to a range that includes the second through last row of columns 3 and 4 in the current region for cell A1.

Sub GetRange()

   Dim rngCurRegion
   Dim rngTempRange

   Set rngCurRegion = Spreadsheet1.Range("a1").CurrentRegion

   Set rngTempRange = rngCurRegion.Range(rngCurRegion.Cells(2, 3), _
       curRegion.Cells(rngCurRegion.Rows.Count, 4))

End Sub